<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>title</title>
  <script src='vue/vue.js'></script>
</head>

<body>
  <div id="root">
    <table>
      <tbody>
        <tr is="row"></tr>
        <tr is="row"></tr>
        <tr is="row"></tr>
        <tr is="row"></tr>
      </tbody>
    </table>
  </div>
  <script>
    Vue.component('row',{
      data:function(){ //子组件里的data必须是一个function,原因是每个子组件的数据不能相互影响
        return {
          content:"this is vue"
        }
      },
      template:"<tr><td>{{content}}</td></tr>"
    })
    var vm = new Vue({
      el:"#root",
      data:{}
    })
  </script>
</body>

</html>